﻿using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Text;
using System.Threading;
using FitAutomation.FitProcess;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using MyUtils;

namespace FitProcess_UnitTests
{
	[TestClass]
	public class Should_use_console_only_for_debug
	{
		[TestMethod]
		public void Should_not_show_console_by_default()
		{
			using (FitProcessFactory.CreateProcess())
			{
				Thread.Sleep(1000);
			}
		}

		[TestMethod]
		public void Should_show_console_on_debugging()
		{
			//Assert.IsTrue(Debugger.IsAttached);
			DebugUtils.DebuggerReattaching();
			using (FitProcessFactory.CreateProcess(true))
			{
				Thread.Sleep(1000);
			}
		}
	}
}
